<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Logagent: src/logagent-list.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Logagent
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#define-members">Macros</a>  </div>
  <div class="headertitle">
<div class="title">logagent-list.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p><a href="logagent-list_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structlist__head.html">list_head</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:afd049f7ad59dbe455f460807475c2841"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#afd049f7ad59dbe455f460807475c2841">offsetof</a>(type,  member)&#160;&#160;&#160;(size_t)(&amp;((type*)0)-&gt;member)</td></tr>
<tr class="separator:afd049f7ad59dbe455f460807475c2841"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af8c317a42292b61c93aae91e59118a46"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#af8c317a42292b61c93aae91e59118a46">container_of</a>(ptr,  type,  member)&#160;&#160;&#160;(type *)((char*)(ptr) - <a class="el" href="logagent-plugin-list_8h.html#afd049f7ad59dbe455f460807475c2841">offsetof</a>(type, member))</td></tr>
<tr class="separator:af8c317a42292b61c93aae91e59118a46"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4642d4b7df28478bb762fe43c85b5c63"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#a4642d4b7df28478bb762fe43c85b5c63">LIST_HEAD_INIT</a>(name)&#160;&#160;&#160;{&amp;(name), &amp;(name)}</td></tr>
<tr class="separator:a4642d4b7df28478bb762fe43c85b5c63"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a42f0e72af970a790b60a740af8c9ecd0"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#a42f0e72af970a790b60a740af8c9ecd0">LIST_HEAD</a>(name)&#160;&#160;&#160;struct <a class="el" href="structlist__head.html">list_head</a> name = <a class="el" href="logagent-plugin-list_8h.html#a4642d4b7df28478bb762fe43c85b5c63">LIST_HEAD_INIT</a>(name)</td></tr>
<tr class="separator:a42f0e72af970a790b60a740af8c9ecd0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a26c976b7f654e70df318c1843e5094de"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#a26c976b7f654e70df318c1843e5094de">list_entry</a>(ptr,  type,  member)&#160;&#160;&#160;<a class="el" href="logagent-plugin-list_8h.html#af8c317a42292b61c93aae91e59118a46">container_of</a>(ptr, type, member)</td></tr>
<tr class="separator:a26c976b7f654e70df318c1843e5094de"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29b80cf9d55392a4949d2071b7db4d5c"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#a29b80cf9d55392a4949d2071b7db4d5c">list_first_entry</a>(ptr,  type,  member)&#160;&#160;&#160;<a class="el" href="logagent-plugin-list_8h.html#a26c976b7f654e70df318c1843e5094de">list_entry</a>((ptr)-&gt;next, type, member)</td></tr>
<tr class="separator:a29b80cf9d55392a4949d2071b7db4d5c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2491a0347c32716e8a1cbfe6bcaaf8d0"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#a2491a0347c32716e8a1cbfe6bcaaf8d0">list_next_entry</a>(pos,  type,  member)&#160;&#160;&#160;<a class="el" href="logagent-plugin-list_8h.html#a26c976b7f654e70df318c1843e5094de">list_entry</a>((pos)-&gt;member.next, type, member)</td></tr>
<tr class="separator:a2491a0347c32716e8a1cbfe6bcaaf8d0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab8b24e6660ab3760c923e4b4db3fa502"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#ab8b24e6660ab3760c923e4b4db3fa502">list_for_each</a>(pos,  head)&#160;&#160;&#160;for (pos = (head)-&gt;next; pos != (head); pos = pos-&gt;next)</td></tr>
<tr class="separator:ab8b24e6660ab3760c923e4b4db3fa502"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9e4b9328744994b9d3878f5dad75c09f"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#a9e4b9328744994b9d3878f5dad75c09f">list_for_each_safe</a>(pos,  n,  head)</td></tr>
<tr class="separator:a9e4b9328744994b9d3878f5dad75c09f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:affa1004871252442b1970bca1a803a33"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#affa1004871252442b1970bca1a803a33">list_for_each_entry</a>(pos,  type,  head,  member)</td></tr>
<tr class="separator:affa1004871252442b1970bca1a803a33"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa7487ba2d0d9b1435d413751a869344c"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="logagent-list_8h.html#aa7487ba2d0d9b1435d413751a869344c">list_for_each_entry_safe</a>(pos,  type,  n,  head,  member)</td></tr>
<tr class="separator:aa7487ba2d0d9b1435d413751a869344c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Macro Definition Documentation</h2>
<a id="af8c317a42292b61c93aae91e59118a46"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af8c317a42292b61c93aae91e59118a46">&#9670;&nbsp;</a></span>container_of</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define container_of</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ptr, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;(type *)((char*)(ptr) - <a class="el" href="logagent-plugin-list_8h.html#afd049f7ad59dbe455f460807475c2841">offsetof</a>(type, member))</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="a26c976b7f654e70df318c1843e5094de"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a26c976b7f654e70df318c1843e5094de">&#9670;&nbsp;</a></span>list_entry</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_entry</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ptr, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;<a class="el" href="logagent-plugin-list_8h.html#af8c317a42292b61c93aae91e59118a46">container_of</a>(ptr, type, member)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>list_entry - get the struct for this entry </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">ptr</td><td>the &amp;struct <a class="el" href="structlist__head.html">list_head</a> pointer. </td></tr>
    <tr><td class="paramname">type</td><td>the type of the struct this is embedded in. </td></tr>
    <tr><td class="paramname">member</td><td>the name of the <a class="el" href="structlist__head.html">list_head</a> within the struct. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a29b80cf9d55392a4949d2071b7db4d5c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a29b80cf9d55392a4949d2071b7db4d5c">&#9670;&nbsp;</a></span>list_first_entry</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_first_entry</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">ptr, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;<a class="el" href="logagent-plugin-list_8h.html#a26c976b7f654e70df318c1843e5094de">list_entry</a>((ptr)-&gt;next, type, member)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>list_first_entry - get the first element from a list </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">ptr</td><td>the list head to take the element from. </td></tr>
    <tr><td class="paramname">type</td><td>the type of the struct this is embedded in. </td></tr>
    <tr><td class="paramname">member</td><td>the name of the <a class="el" href="structlist__head.html">list_head</a> within the struct.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>that list is expected to be not empty. </dd></dl>

</div>
</div>
<a id="ab8b24e6660ab3760c923e4b4db3fa502"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab8b24e6660ab3760c923e4b4db3fa502">&#9670;&nbsp;</a></span>list_for_each</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_for_each</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pos, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">head&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;for (pos = (head)-&gt;next; pos != (head); pos = pos-&gt;next)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>list_for_each - iterate over a list </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pos</td><td>the &amp;struct <a class="el" href="structlist__head.html">list_head</a> to use as a loop cursor. </td></tr>
    <tr><td class="paramname">head</td><td>the head for your list. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="affa1004871252442b1970bca1a803a33"></a>
<h2 class="memtitle"><span class="permalink"><a href="#affa1004871252442b1970bca1a803a33">&#9670;&nbsp;</a></span>list_for_each_entry</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_for_each_entry</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pos, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">head, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line"><span class="keywordflow">for</span> (pos = <a class="code" href="logagent-list_8h.html#a29b80cf9d55392a4949d2071b7db4d5c">list_first_entry</a>(head, type, member);    \</div><div class="line">         &amp;pos-&gt;member != (head);                    \</div><div class="line">         pos = <a class="code" href="logagent-list_8h.html#a2491a0347c32716e8a1cbfe6bcaaf8d0">list_next_entry</a>(pos, type, member))</div><div class="ttc" id="logagent-list_8h_html_a29b80cf9d55392a4949d2071b7db4d5c"><div class="ttname"><a href="logagent-list_8h.html#a29b80cf9d55392a4949d2071b7db4d5c">list_first_entry</a></div><div class="ttdeci">#define list_first_entry(ptr, type, member)</div><div class="ttdef"><b>Definition:</b> logagent-list.h:51</div></div>
<div class="ttc" id="logagent-list_8h_html_a2491a0347c32716e8a1cbfe6bcaaf8d0"><div class="ttname"><a href="logagent-list_8h.html#a2491a0347c32716e8a1cbfe6bcaaf8d0">list_next_entry</a></div><div class="ttdeci">#define list_next_entry(pos, type, member)</div><div class="ttdef"><b>Definition:</b> logagent-list.h:60</div></div>
</div><!-- fragment --><p>list_for_each_entry - iterate over list of given type </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pos</td><td>the type * to use as a loop cursor. </td></tr>
    <tr><td class="paramname">type</td><td>the type of pos </td></tr>
    <tr><td class="paramname">head</td><td>the head for your list. </td></tr>
    <tr><td class="paramname">member</td><td>the name of the <a class="el" href="structlist__head.html">list_head</a> within the struct. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="aa7487ba2d0d9b1435d413751a869344c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa7487ba2d0d9b1435d413751a869344c">&#9670;&nbsp;</a></span>list_for_each_entry_safe</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_for_each_entry_safe</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pos, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">n, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">head, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line"><span class="keywordflow">for</span> (pos = <a class="code" href="logagent-list_8h.html#a29b80cf9d55392a4949d2071b7db4d5c">list_first_entry</a>(head, type, member),    \</div><div class="line">        n = <a class="code" href="logagent-list_8h.html#a2491a0347c32716e8a1cbfe6bcaaf8d0">list_next_entry</a>(pos, type, member);         \</div><div class="line">         &amp;pos-&gt;member != (head);                    \</div><div class="line">         pos = n, n = <a class="code" href="logagent-list_8h.html#a2491a0347c32716e8a1cbfe6bcaaf8d0">list_next_entry</a>(n, type, member))</div><div class="ttc" id="logagent-list_8h_html_a29b80cf9d55392a4949d2071b7db4d5c"><div class="ttname"><a href="logagent-list_8h.html#a29b80cf9d55392a4949d2071b7db4d5c">list_first_entry</a></div><div class="ttdeci">#define list_first_entry(ptr, type, member)</div><div class="ttdef"><b>Definition:</b> logagent-list.h:51</div></div>
<div class="ttc" id="logagent-list_8h_html_a2491a0347c32716e8a1cbfe6bcaaf8d0"><div class="ttname"><a href="logagent-list_8h.html#a2491a0347c32716e8a1cbfe6bcaaf8d0">list_next_entry</a></div><div class="ttdeci">#define list_next_entry(pos, type, member)</div><div class="ttdef"><b>Definition:</b> logagent-list.h:60</div></div>
</div><!-- fragment --><p>list_for_each_entry_safe - iterate over list of given type safe against removal of list entry </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pos</td><td>the type * to use as a loop cursor. </td></tr>
    <tr><td class="paramname">type</td><td>the type of pos </td></tr>
    <tr><td class="paramname">n</td><td>another type * to use as temporary storage </td></tr>
    <tr><td class="paramname">head</td><td>the head for your list. </td></tr>
    <tr><td class="paramname">member</td><td>the name of the <a class="el" href="structlist__head.html">list_head</a> within the struct. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a9e4b9328744994b9d3878f5dad75c09f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9e4b9328744994b9d3878f5dad75c09f">&#9670;&nbsp;</a></span>list_for_each_safe</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_for_each_safe</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pos, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">n, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">head&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line"><span class="keywordflow">for</span> (pos = (head)-&gt;<a class="code" href="structlist__head.html#afb6f2172d12efd37f00bb623a6885f2a">next</a>, n = pos-&gt;<a class="code" href="structlist__head.html#afb6f2172d12efd37f00bb623a6885f2a">next</a>; pos != (head); \</div><div class="line">        pos = n, n = pos-&gt;<a class="code" href="structlist__head.html#afb6f2172d12efd37f00bb623a6885f2a">next</a>)</div><div class="ttc" id="structlist__head_html_afb6f2172d12efd37f00bb623a6885f2a"><div class="ttname"><a href="structlist__head.html#afb6f2172d12efd37f00bb623a6885f2a">list_head::next</a></div><div class="ttdeci">struct list_head * next</div><div class="ttdef"><b>Definition:</b> logagent-list.h:27</div></div>
</div><!-- fragment --><p>list_for_each_safe - iterate over a list safe against removal of list entry </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pos</td><td>the &amp;struct <a class="el" href="structlist__head.html">list_head</a> to use as a loop cursor. </td></tr>
    <tr><td class="paramname">n</td><td>another &amp;struct <a class="el" href="structlist__head.html">list_head</a> to use as temporary storage </td></tr>
    <tr><td class="paramname">head</td><td>the head for your list. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a42f0e72af970a790b60a740af8c9ecd0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a42f0e72af970a790b60a740af8c9ecd0">&#9670;&nbsp;</a></span>LIST_HEAD</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define LIST_HEAD</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">name</td><td>)</td>
          <td>&#160;&#160;&#160;struct <a class="el" href="structlist__head.html">list_head</a> name = <a class="el" href="logagent-plugin-list_8h.html#a4642d4b7df28478bb762fe43c85b5c63">LIST_HEAD_INIT</a>(name)</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="a4642d4b7df28478bb762fe43c85b5c63"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4642d4b7df28478bb762fe43c85b5c63">&#9670;&nbsp;</a></span>LIST_HEAD_INIT</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define LIST_HEAD_INIT</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">name</td><td>)</td>
          <td>&#160;&#160;&#160;{&amp;(name), &amp;(name)}</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="a2491a0347c32716e8a1cbfe6bcaaf8d0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2491a0347c32716e8a1cbfe6bcaaf8d0">&#9670;&nbsp;</a></span>list_next_entry</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define list_next_entry</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pos, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;<a class="el" href="logagent-plugin-list_8h.html#a26c976b7f654e70df318c1843e5094de">list_entry</a>((pos)-&gt;member.next, type, member)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>list_next_entry - get the next element in list </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pos</td><td>the type * to cursor </td></tr>
    <tr><td class="paramname">type</td><td>the type of pos </td></tr>
    <tr><td class="paramname">member</td><td>the name of the <a class="el" href="structlist__head.html">list_head</a> within the struct. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="afd049f7ad59dbe455f460807475c2841"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afd049f7ad59dbe455f460807475c2841">&#9670;&nbsp;</a></span>offsetof</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define offsetof</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">member&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;(size_t)(&amp;((type*)0)-&gt;member)</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.14
</small></address>
</body>
</html>
